package com.bankwel.j2d.ui;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JPanel;

import com.bankwel.j2d.core.J2dMatrix;
import com.bankwel.j2d.model.Object2d;

public class J2dProxy implements ActionListener {

	private Object2d obj;
	private JPanel panel;
	private J2dMatrix action;

	public J2dProxy(Object2d obj, JPanel panel, J2dMatrix action) {
		super();
		this.obj = obj;
		this.panel = panel;
		this.action = action;
	}

	@Override
	public void actionPerformed(ActionEvent e) {
		// TODO
		panel.repaint();
		obj.transformBy(action);
		//System.out.println(action.det());
	}

}
